/*
 * To change this template, choose Tools | Templates
 * and open the template in the editor.
 */
package trefliq.EJB.webservice;

import java.util.List;
import javax.ejb.EJB;
import javax.jws.WebService;
import javax.ejb.Stateless;
import javax.jws.WebMethod;
import javax.jws.WebParam;
import trefliq.EJB.entities.Credit;
import trefliq.EJB.sessionbeans.CreditBean;

/**
 *
 * @author Adam Gojdas
 */
//@WebService(serviceName = "CreditWebService")
@Stateless()
public class CreditWebService {
    @EJB
    private CreditBean ejbRef;// Add business logic below. (Right-click in editor and choose
    // "Insert Code > Add Web Service Operation")

    @WebMethod(operationName = "setCreditinmovie")
    public Long setCreditinmovie(@WebParam(name = "creditinmovie") String creditinmovie) {
        return ejbRef.setCreditinmovie(creditinmovie);
    }

    @WebMethod(operationName = "getCredits")
    public String getCredits() {
        return ejbRef.getCredits();
    }

    @WebMethod(operationName = "getAllCredits")
    public List<Credit> getAllCredits() {
        return ejbRef.getAllCredits();
    }
    
}
